package com.study.decorator.impl;

import com.study.decorator.MilkyTea;
import com.study.decorator.MilkyTeaDecorator;

/**
 * 椰果奶茶
 */
public class CoconutDecorator extends MilkyTeaDecorator {
    public CoconutDecorator(MilkyTea milkyTea) {
        super(milkyTea);
    }


    @Override
    public double cost() {
        System.out.println("添加椰果");
        return super.cost() + 2.0;
    }

}
